<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div>
        <input type="text" id="username">
        <input type="text" id="password">
        <button id="btn">登录</button>
    </div>
    <script>
    let btn = document.getElementById('btn')
    btn.addEventListener('click', () => {
      fetch('http://localhost:3000/login?username=2025&password=123456', {
        method: 'GET'
      }).then((response) => {
        return response.json()
      }).then((data) => {
        console.log(data);
      })
    })
    </script>
</body>
</html>